package com.sf.osms.dep.domain;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.hibernate.annotations.Polymorphism;
import org.hibernate.annotations.PolymorphismType;

import com.sf.novatar.base.domain.LongIdBean;
/**
 * 上传的Handover数据
 * @author 841245
 *
 */
@Entity
@Table(name = "wbs_tt_handover")
@Polymorphism(type = PolymorphismType.EXPLICIT)
public class Handover extends LongIdBean implements Serializable{
	
	private static final long serialVersionUID = 1L;
	
	/**
	 * ID
	 */
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name = "ID", unique = true, nullable = false)
	private Long id;
	
	/**
	 * 文件名称
	 */
	@Column(name = "FILE_NAME")
	private String fileName;
	
	/**
	 * 用户ID
	 */
	@Column(name = "USER_ID")
	private Long userId;
	
	/**
	 * 创建时间
	 */
	@Column(name = "CREATE_TIME")
	private Date createTime;
	
	/**
	 * 国家代码
	 */
	@Column(name = "COUNTRY_CODE") //
	private String countryCode;
	
	
	/**
	 * 代理ID
	 */
	@Column(name = "AGENT_ID")
	private Long agentId;
	
	/**
	 * 网点
	 */
	@Column(name = "NETWORK")
	private String network;
	
	/**
	 * 顺丰运单号
	 */
	@Column(name = "SF_WAYBILL")
	private String sfWaybill;
	
	/**
	 * 代理运单号
	 */
	@Column(name = "AGENT_WAYBILL")
	private String agentWaybill;
	
	/**
	 * 存放路径
	 */
	@Column(name = "PATH")
	private String path;
	
	/**
	 * 当前状态 N:新建，M:碰撞成功, F:碰撞失败
	 */
	@Column(name = "STATUS")
	private String status;
	
	/**
	 * 碰撞时间
	 */
	@Column(name = "MATCH_DATE")
	private Date matchDate;
	
	
	/**
	 * 失败原因
	 */
	@Column(name = "FAIL_REASON")
	private String failReason;
	
	/***2.4扩展字段***/
	/**
	 * 收件方地址
	 */
	@Column(name = "receiver_address")
	private String receiverAddress;
	
	/**
	 * 收件方邮编
	 */
	@Column(name = "reciever_postal_code")
	private String recieverPostalCode;
	
	/**
	 * 收件人姓名
	 */
	@Column(name = "receiver")
	private String receiver;
	
	/**
	 * 收件人电话
	 */
	@Column(name = "receiver_phone")
	private String receiverPhone;
	
	/**
	 * 支付条款
	 */
	@Column(name = "freight_term")
	private String freightTerm;
	
	/**
	 * 件数
	 */
	@Column(name = "piece")
	private String piece;
	
	/**
	 * 重量
	 */
	@Column(name = "weight")
	private String weight;
	
	/**
	 * 快件类型
	 */
	@Column(name = "shipment_Type")
	private String shipmentType;
	
	/**
	 * 运费
	 */
	@Column(name = "freight_Amount")
	private String freightAmount;
	
	/**
	 * 税金
	 */
	@Column(name = "tax_Duties")
	private String taxDuties;
	
	/**
	 * 总金额
	 */
	@Column(name = "total")
	private String total;
	
	/**
	 * 修改日期
	 */
	@Column(name = "modify_date")
	private Date modifyDate;
	
	/**
	 * 修改者
	 */
	@Column(name = "modifier_ID")
	private Long modifierId;
	
	/**
	 * 行号
	 */
	@Transient
	private Integer lineNum;
	
	public Integer getLineNum() {
		return lineNum;
	}


	public void setLineNum(Integer lineNum) {
		this.lineNum = lineNum;
	}


	@Override
	protected Long getId() {
		return this.id;
	}


	public String getFileName() {
		return fileName;
	}


	public void setFileName(String fileName) {
		this.fileName = fileName;
	}


	public Long getUserId() {
		return userId;
	}


	public void setUserId(Long userId) {
		this.userId = userId;
	}


	public Date getCreateTime() {
		return createTime;
	}


	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}


	public String getCountryCode() {
		return countryCode;
	}


	public void setCountryCode(String countryCode) {
		this.countryCode = countryCode;
	}


	public Long getAgentId() {
		return agentId;
	}


	public void setAgentId(Long agentId) {
		this.agentId = agentId;
	}


	public String getNetwork() {
		return network;
	}


	public void setNetwork(String network) {
		this.network = network;
	}


	public String getSfWaybill() {
		return sfWaybill;
	}


	public void setSfWaybill(String sfWaybill) {
		this.sfWaybill = sfWaybill;
	}


	public String getAgentWaybill() {
		return agentWaybill;
	}


	public void setAgentWaybill(String agentWaybill) {
		this.agentWaybill = agentWaybill;
	}


	public String getPath() {
		return path;
	}


	public void setPath(String path) {
		this.path = path;
	}


	public String getStatus() {
		return status;
	}


	public void setStatus(String status) {
		this.status = status;
	}


	public Date getMatchDate() {
		return matchDate;
	}


	public void setMatchDate(Date matchDate) {
		this.matchDate = matchDate;
	}


	public String getFailReason() {
		return failReason;
	}


	public void setFailReason(String failReason) {
		this.failReason = failReason;
	}


	public void setId(Long id) {
		this.id = id;
	}


	public String getReceiverAddress() {
		return receiverAddress;
	}


	public void setReceiverAddress(String receiverAddress) {
		this.receiverAddress = receiverAddress;
	}


	public String getRecieverPostalCode() {
		return recieverPostalCode;
	}


	public void setRecieverPostalCode(String recieverPostalCode) {
		this.recieverPostalCode = recieverPostalCode;
	}


	public String getReceiver() {
		return receiver;
	}


	public void setReceiver(String receiver) {
		this.receiver = receiver;
	}


	public String getReceiverPhone() {
		return receiverPhone;
	}


	public void setReceiverPhone(String receiverPhone) {
		this.receiverPhone = receiverPhone;
	}


	public String getFreightTerm() {
		return freightTerm;
	}


	public void setFreightTerm(String freightTerm) {
		this.freightTerm = freightTerm;
	}


	public String getPiece() {
		return piece;
	}


	public void setPiece(String piece) {
		this.piece = piece;
	}


	public String getWeight() {
		return weight;
	}


	public void setWeight(String weight) {
		this.weight = weight;
	}


	public String getShipmentType() {
		return shipmentType;
	}


	public void setShipmentType(String shipmentType) {
		this.shipmentType = shipmentType;
	}


	public String getFreightAmount() {
		return freightAmount;
	}


	public void setFreightAmount(String freightAmount) {
		this.freightAmount = freightAmount;
	}


	public String getTaxDuties() {
		return taxDuties;
	}


	public void setTaxDuties(String taxDuties) {
		this.taxDuties = taxDuties;
	}


	public String getTotal() {
		return total;
	}


	public void setTotal(String total) {
		this.total = total;
	}


	@Override
	public String toString() {
		return "Handover [id=" + id + ", fileName=" + fileName + ", userId="
				+ userId + ", createTime=" + createTime + ", countryCode="
				+ countryCode + ", agentId=" + agentId + ", network=" + network
				+ ", sfWaybill=" + sfWaybill + ", agentWaybill=" + agentWaybill
				+ ", path=" + path + ", status=" + status + ", matchDate="
				+ matchDate + ", failReason=" + failReason
				+ ", receiverAddress=" + receiverAddress
				+ ", recieverPostalCode=" + recieverPostalCode + ", receiver="
				+ receiver + ", receiverPhone=" + receiverPhone
				+ ", freightTerm=" + freightTerm + ", piece=" + piece
				+ ", weight=" + weight + ", shipmentType=" + shipmentType
				+ ", freightAmount=" + freightAmount + ", taxDuties="
				+ taxDuties + ", total=" + total + ", modifyDate=" + modifyDate
				+ ", modifierId=" + modifierId + ", lineNum=" + lineNum + "]";
	}


	public Date getModifyDate() {
		return modifyDate;
	}


	public void setModifyDate(Date modifyDate) {
		this.modifyDate = modifyDate;
	}


	public Long getModifierId() {
		return modifierId;
	}


	public void setModifierId(Long modifierId) {
		this.modifierId = modifierId;
	}
	
	
	
	

}
